// browser detect
var browserDetect = function(){
	// user agent
	this.ua = navigator.userAgent.toLowerCase();
	// version
	this.isIE = ( (this.ua.indexOf("msie") != -1) && (this.ua.indexOf("opera") == -1) && (this.ua.indexOf("webtv") == -1) );
	this.isMozilla   = (this.isGecko && this.ua.indexOf("gecko/") + 14 == this.ua.length);
	// minor version
	this.versionMinor = parseFloat(navigator.appVersion);
	// correct version number for IE4+
	if(this.isIE && this.versionMinor >= 4){ this.versionMinor = parseFloat( this.ua.substring( this.ua.indexOf('msie ') + 5 ) ); }
	// platform
	this.isWin   = (this.ua.indexOf('win') != -1);
	this.isWin32 = (this.isWin && ( this.ua.indexOf('95') != -1 || this.ua.indexOf('98') != -1 || this.ua.indexOf('nt') != -1 || this.ua.indexOf('win32') != -1 || this.ua.indexOf('32bit') != -1) );
	this.isMac   = (this.ua.indexOf('mac') != -1);
	this.isUnix  = (this.ua.indexOf('unix') != -1 || this.ua.indexOf('linux') != -1 || this.ua.indexOf('sunos') != -1 || this.ua.indexOf('bsd') != -1 || this.ua.indexOf('x11') != -1)
};

// initiate browsercheck object
var browser = new browserDetect();